<template>
  <div class="breadcrumb">
    <el-breadcrumb separator="/">
      <template v-for="item in breads" :key="item.name">
        <el-breadcrumb-item>{{item.name}}</el-breadcrumb-item>
      </template>
    </el-breadcrumb>
  </div>
</template>

<script lang="ts">
import { defineComponent, PropType } from 'vue'
import { IBreadItem } from '../types'
export default defineComponent({
  props: {
    breads: {
      type: Array as PropType<IBreadItem[]>,
      default: () => []
    }
  },
  setup() {
    return {}
  }
})
</script>

<style scoped lang="less">
.breadcrumb {
  margin-bottom: 20px;
}
</style>